package personal.lijun.skeleton.web.configuration;

import org.springframework.boot.web.servlet.ServletListenerRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.web.context.request.RequestContextListener;

/**
 * @Auther: lijun@sstcsoft.com
 * @Date: 2019/9/16 18:05
 */
@Configuration
@Import({SecurityConfig.class})
public class JavaConfig {
    @Bean("requestContextListener")
    public ServletListenerRegistrationBean<RequestContextListener> RequestContextListener(){
        RequestContextListener requestContextListener = new RequestContextListener();
        return new ServletListenerRegistrationBean<>(requestContextListener);
    }
}
